<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<script src="vue.js" type="text/javascript" charset="utf-8"></script>
	</head>
	<body>
		<div id="app">
			{{msg}}
			<!-- 点击按钮触发弹窗 -->
			<button v-on:click="fun1">Vue的click</button>
			<button v-on:click="fun2('方法二')">我是方法二</button>
		</div>
		<script type="text/javascript">
			var vm = new Vue({
				el:'#app',
				data:{
					msg:"I love Vue"
				},
				methods:{
					fun1(){
						// 弹窗
						alert("Hi");
					},
					fun2(msg){
						this.msg = msg;
						alert(msg);
					}
				}
			});
		</script>


	</body>
</html>
